<div class="modal" ng-controller="KisBpmChoseAssignmentCtrl">
	<div class="modal-dialog">
		<div class="modal-content">
			<div class="modal-header">
				<button type="button" class="close" data-dismiss="modal" aria-hidden="true" ng-click="close()">&times;</button>
				<h2 translate>PROPERTY.ASSIGNMENT.TITLE</h2>
			</div>
			<div class="modal-body">
				<div class="tabs">
					<ul class="nav nav-tabs">
						<li role="presentation" ng-class="{active:tab == 'user'}" ng-click="tab = 'user'"><a href="#">用户列表</a></li>
						<li role="presentation" ng-class="{active:tab == 'job'}" ng-click="tab = 'job'"><a href="#">职务列表</a></li>
						<li role="presentation" ng-class="{active:tab == 'role'}" ng-click="tab = 'role'"><a href="#">角色列表</a></li>
					</ul>
				</div>
				<div class="row row-no-gutter" ng-if="tab == 'user'">
					<!-- <div class="col-xs-3">
						<div class="stencils" id="z_tree">
							<div ng-repeat="role in roles">
								<ul class="stencil-group"  ng-class="{collapsed: !group.expanded, 'first': $first}">
									<li>
				                            	<span ng-click="getAllAccountByRole(role.id)" >
											        {{role.name}}
											    </span>
									</li>
								</ul>
							</div>
						</div>
					</div> -->

					<!--<input type="radio" ng-model="kk" name="accountIds" ng-value="1" >-->
					<!--<input type="radio" ng-model="kk" name="accountIds" ng-value="0" >-->

					<div class="col-xs-12">
						<table class="table table-bordered table-condensed">
							<thead>
							<tr>
								<th><input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-click="selectAll($event)"></th>
								<th>用户列表</th>
							</tr>
							</thead>
							<tbody>
							<tr ng-repeat="user in users">
								<td>
									<!--<input ng-if="choseAssignmentFlag=='assignee'" type="radio"   name="accountIdinfo"  ng-value="{{account.id}}"-->
									 <!--ng-model="cardRadio"  ng-model="$parent.cardRadio" value="{{account.id}}" ng-checked="$index==0?true:false">-->

									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="1"  ng-false-value="false">-->
									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="0"  ng-false-value="false">-->
									<input ng-if="choseAssignmentFlag=='assignee'" type="radio" ng-model="user.checked" name="userId" value="{{user.id}}"
										  >

									<input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-model="user.selected" ne-true-value="{{user.id}}"
										   ng-false-value="false">
								</td>
								<td>{{user.name}}</td>
							</tr>
							</tbody>
						</table>
					</div>
				</div>

				<div class="row row-no-gutter" ng-if="tab == 'role'">
					<div class="col-xs-12">
						<table class="table table-bordered table-condensed">
							<thead>
							<tr>
								<th><input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-click="selectAll($event)"></th>
								<th>角色列表</th>
							</tr>
							</thead>
							<tbody>
							<tr ng-repeat="role in roles">
								<td>
									<!--<input ng-if="choseAssignmentFlag=='assignee'" type="radio"   name="accountIdinfo"  ng-value="{{account.id}}"-->
									 <!--ng-model="cardRadio"  ng-model="$parent.cardRadio" value="{{account.id}}" ng-checked="$index==0?true:false">-->

									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="1"  ng-false-value="false">-->
									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="0"  ng-false-value="false">-->
									<input ng-if="choseAssignmentFlag=='assignee'" type="radio" ng-model="role.checked" name="roleId" value="{{role.id}}"
										  >

									<input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-model="role.selected" ne-true-value="{{role.id}}"
										   ng-false-value="false">
								</td>
								<td>{{role.name}}</td>
							</tr>
							</tbody>
						</table>
					</div>
				</div>
				<div class="row row-no-gutter" ng-if="tab == 'job'">
					<div class="col-xs-12">
						<table class="table table-bordered table-condensed">
							<thead>
							<tr>
								<th><input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-click="selectAll($event)"></th>
								<th>职务列表</th>
							</tr>
							</thead>
							<tbody>
							<tr ng-repeat="job in jobs">
								<td>
									<!--<input ng-if="choseAssignmentFlag=='assignee'" type="radio"   name="accountIdinfo"  ng-value="{{account.id}}"-->
									 <!--ng-model="cardRadio"  ng-model="$parent.cardRadio" value="{{account.id}}" ng-checked="$index==0?true:false">-->

									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="1"  ng-false-value="false">-->
									<!--<input type="radio" ng-model="$parent.kk" name="accountIds" ne-true-value="0"  ng-false-value="false">-->
									<input ng-if="choseAssignmentFlag=='assignee'" type="radio" ng-model="job.checked" name="jobId" value="{{job.id}}"
										  >

									<input ng-if="choseAssignmentFlag=='assignees'" type="checkbox" ng-model="job.selected" ne-true-value="{{job.id}}"
										   ng-false-value="false">
								</td>
								<td>{{job.name}}</td>
							</tr>
							</tbody>
						</table>
					</div>
				</div>

			</div>
			<div class="modal-footer">


				<div>
					<p style="float: left;margin-top: 7px;"></p>
					<tm-pagination conf="paginationConf"></tm-pagination>
				</div>

				<button ng-click="close()"  translate class="btn btn-inverse">ACTION.CANCEL</button>
				<button ng-click="save()"  class="btn btn-primary" translate>ACTION.SAVE</button>
			</div>
		</div>
	</div>
</div>